/*
 * Copyright (c) 2020, 2023, 3044483124@qq.com All rights reserved.
 *
 */
package cn.itcast;

import java.util.Scanner;

/**
 * <p>Project: JavaStudy - Input2
 * <p>Powered by jiangbo On 2023-02-04
 * 17:59:22
 * <p>Created by IntelliJ IDEA
 *
 * @author jiangbo [3044483124@qq.com]
 * @version 1.0
 * @since 8/17
 */
public class Input2 {
    public static void main(String[] args) {
        //使用的java.util.Scanner 工具类，实现的输入
        Scanner sc = new Scanner(System.in);
        System.out.println("请输入两个数：");
        int a = sc.nextInt();
        int b = sc.nextInt();
        if (a % b == 0) {
            System.out.printf("%d ÷ %d = %d%n", a, b, a / b);
        } else {
            System.out.printf("%d ÷ %d = %d ... %d%n", a, b, a / b, a % b);
        }
    }
}


